package com.demo.drools.rules.config;

import com.alibaba.fastjson.annotation.JSONField;
import com.alibaba.fastjson.annotation.JSONType;
import com.demo.drools.dal.enums.RuleType;
import com.demo.drools.rules.fact.Fact;
import lombok.Data;

import java.io.Serializable;

/**
 * @author ZhouSicheng
 * @description
 * @date 2019/3/15 11:55
 */
@Data
@JSONType(seeAlso = {DiscountRuleConfig.class, ReduceRuleConfig.class})
public abstract class BaseCouponRuleConfig implements Serializable {

    /**
     * 最大减免
     */
    protected Long maxCent = Long.MAX_VALUE;

    /**
     * 最小的可以享受优惠的数量
     */
    protected Long lowerCent = 0L;

    protected RuleType ruleType;

    @JSONField(serialize = false)
    protected Fact fact;
}
